package org.example.test;

import org.example.config.springconfig;
import org.example.entity.user;
import org.example.service.userservice;
import org.springframework.context.annotation.AnnotationConfigApplicationContext;

public class test1 {
    public static void main(String[] args) {

        AnnotationConfigApplicationContext context = new AnnotationConfigApplicationContext(springconfig.class);
        userservice bean = context.getBean(userservice.class);
        user user = bean.selectById(2);
        System.out.println(user);


    }

}
